#pragma once
#include "../Ode.h"

namespace Skill
{
	namespace Ode
	{
		namespace Joints
		{		
		}
		namespace Geometries
		{		
			ref class DGeometry;
		}
	}
}
using namespace Skill::Ode::Joints;
using namespace Skill::Ode::Geometries;
namespace Skill
{
	namespace Ode
	{		
		ref class DAabb;
		ref class DVector3;
		ref class DMatrix3;

		public ref class DUtility abstract sealed
		{
		public:			

			static void ClosestLineSegmentPoints (DVector3^ a1, DVector3^ a2,
				DVector3^ b1, DVector3^ b2,
				DVector3^ cp1, DVector3^ cp2);

			static bool BoxTouchesBox(DVector3^ _p1,  DMatrix3^ R1,
					DVector3^ side1, DVector3^ _p2,
					DMatrix3^ R2, DVector3^ side2);


			/*int BoxBox(DVector3^ p1, DMatrix3^ R1,
					DVector3^  side1, DVector3^ p2,
					DMatrix3^ R2, DVector3^ side2,
					DVector3^ normal, dReal *depth, int *return_code,
					int flags, dContactGeom *contact, int skip);*/

			static void InfiniteAABB(DGeometry^ geom, DAabb^ aabb);


				/* ************************************************************************ */
				/* custom classes */

				/*typedef void dGetAABBFn (dGeomID, dReal aabb[6]);
				typedef int dColliderFn (dGeomID o1, dGeomID o2,
					int flags, dContactGeom *contact, int skip);
				typedef dColliderFn * dGetColliderFnFn (int num);
				typedef void dGeomDtorFn (dGeomID o);
				typedef int dAABBTestFn (dGeomID o1, dGeomID o2, dReal aabb[6]);

				typedef struct dGeomClass {
					int bytes;
					dGetColliderFnFn *collider;
					dGetAABBFn *aabb;
					dAABBTestFn *aabb_test;
					dGeomDtorFn *dtor;
				} dGeomClass;

				ODE_API int dCreateGeomClass (const dGeomClass *classptr);
				ODE_API void * dGeomGetClassData (dGeomID);
				ODE_API dGeomID dCreateGeom (int classnum);*/

				/**
				* @brief Sets a custom collider function for two geom classes. 
				*
				* @param i The first geom class handled by this collider
				* @param j The second geom class handled by this collider
				* @param fn The collider function to use to determine collisions.
				* @ingroup collide
				*/
				//ODE_API void dSetColliderOverride (int i, int j, dColliderFn *fn);
		};
	}
}